<!--{include file="_header.html"}-->
<!--{include file="_navibar.html"}-->
<!--{include file="_sidebar.html"}-->
<div class="content">
    <div class="header">
        <div class="stats">
            <p class="stat"><!--span class="number"></span--></p>
        </div>
        <h1 class="page-title">添加类别</h1>
    </div>
    <ul class="breadcrumb">
        <li><a href="#">控制面板 </a> <span class="divider">/</span></li>
        <li><a href="./?application=admin&controller=album">作品展示 </a> <span class="divider">/</span></li>
        <li><a href="./?application=admin&controller=album_class">类别管理 </a> <span class="divider">/</span></li>
        <li class="active">添加类别</li>
    </ul>
    <div class="container-fluid">
        <div class="row-fluid">
            <div class="bb-alert alert alert-info" style="display: none;">
                <span>操作成功</span>
            </div>
                  
            <div class="well">
    <ul class="nav nav-tabs">
      <li class="active"><a href="#home" data-toggle="tab">请填写详细信息</a></li>
    </ul>	
	
	<div id="myTabContent" class="tab-content">
		  <div class="tab-pane active in" id="home">
           <form id="tab" method="post" action="./?application=admin&controller=album_class&method=add&action=save">               
				<label>名称</label>
                   <input type="text" name="name" value="" class="input-xlarge" required="true" autofocus="true" > 
				<label>封面</label>
				<input type="text" value="" id="cover" name="cover" class="input-xlarge">                
              <a id="icon_select4" control="cover" class="btn btn-info" style="vertical-align:top">上传图片</a>
                                      				<div class="btn-toolbar">
					<button type="submit" class="btn btn-primary"><strong>提交</strong></button>
				</div>      
			</form>
        </div>
        
<div class="modal hide fade" id="myModal" style="width:300px;top:60%;left:60%;">
  <div class="modal-body">
  <form target="uc" action="./?application=admin&controller=album_class&method=upload" method="post" enctype="multipart/form-data" style="padding:0px; margin:0px;">
<input type="file" name="file" />
<div id="uploaderror"></div>
<input type="text" name="control" id="control" style="display:none;" />
  </div>
  <div class="modal-footer">
    <a href="#" class="btn" data-dismiss="modal">关闭</a>
      <input type="submit" class="btn" value="确定" />
  </div>
  </form>
  <iframe id="uc" name="uc" width="500" height="500" style="display:none;"></iframe>
</div>        
    </div>
</div>
<script>
$('#icon_select1,#icon_select2,#icon_select3,#icon_select4,#icon_select5').click(function(){			
    $('#control').val($(this).attr('control'));	
	$('#myModal').modal({
		backdrop:true,
		keyboard:true,
		show:true
    });	
});
$('.icon').click(function(){
		var obj=$(this);
		$('#icon_preview').removeClass().addClass(obj.text());
		$('#icon_id').val(obj.text());
		$('#myModal').modal('toggle');
});
</script> 
<!--{include file="_footer_common.html"}-->
<!--{include file="_footer.html"}-->